perm filename LOG.SAI[3,PMP] blob sn#008090 filedate 1972-05-28 generic text, type T, neo UTF8
BEGIN INTEGER T,K,J;
INTEGER ARRAY I[1:5];
INTEGER PROCEDURE NAND4(INTEGER A,B,C,D);
	IF A=1 ∧ B=1 ∧ C=1 ∧ D=1 THEN RETURN(0)ELSE RETURN(1);
INTEGER PROCEDURE NAND8(INTEGER A,B,C,D,E,F,G,H);
	IF A=1 ∧ B=1 ∧ C=1 ∧ D=1 ∧ E=1
		∧ F=1 ∧ G=1 ∧ H=1 THEN RETURN(0)ELSE RETURN(1);
INTEGER PROCEDURE AOI(INTEGER I1,I2,I3,I4,J1,J2,J3,K1,K2,L1,L2);
	IF (I1=1 ∧ I2=1 ∧ I3=1 ∧ I4=1)
	  ∨ (J1=1 ∧ J2=1 ∧ J3=1)
	  ∨ (K1=1 ∧ K2=1)
	  ∨ (L1=1 ∧ L2=1) THEN RETURN(0)ELSE RETURN(1);
INTEGER PROCEDURE INV(INTEGER A);
	IF A=1 THEN RETURN(0)ELSE RETURN(1);
INTEGER PROCEDURE ANDD (INTEGER A,B,C);
	IF A=1 ∧ B=1 ∧ C=1 THEN RETURN(1)ELSE RETURN (0);
OPEN (1,"LPT",1,0,1,T,T,T);
OUT(1,"AOI(NDW,MIB,1,DOAD,DND,1,DOAD,1,0,0,0);"&13&10&10);
OUT(1,"NDW	DND	MIB	DOAD	SUB	RESULT"&13&10&10);
FOR I[1]←0 STEP 1 UNTIL 1 DO
FOR I[2]←0 STEP 1 UNTIL 1 DO
FOR I[3]←0 STEP 1 UNTIL 1 DO
FOR I[4]←0 STEP 1 UNTIL 1 DO
FOR I[5]←0 STEP 1 UNTIL 1 DO
BEGIN
J←AOI(I[1],I[3],1,I[4],I[2],1,I[4],1,0,0,0);
FOR K←1 STEP 1 UNTIL 5 DO
  OUT(1,CVS(I[K])&9);
OUT(1,CVS(J)&13&10);
END;
RELEASE(1);
END;END;END;END;